<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=0.5"/>
    <title>404 - 找不到该页面</title>
    <link rel="icon" type="image/x-icon"
          href=""/>
    <style>
        * {
            box-sizing: border-box;
        }

        body {
            margin: 0;
            font-size: 26px;
            user-select: none
        }

        .container {
            position: relative;
            display: flex;
            align-items: center;
            justify-content: center;
            height: 100vh;
            background: #000;
            color: #5c5c5c;
            font-family: arial, sans-serif;
            overflow: hidden;
        }

        .content {
            position: absolute;
            width: 20rem;
            height: 40rem;
            border-radius: 0.75rem;
            max-width: 100%;
            background: white;
            padding: 2rem;
            text-align: center;
            z-index: 99;
            box-shadow: -10px 10px 67px -12px rgba(0, 0, 0, .8);
            opacity: 0;
            animation: apparition 0.5s 0.1s cubic-bezier(0.39, 0.575, 0.28, 0.995) forwards;
        }

        .content p {
            font-size: 1.2rem;
            margin: 2rem 0;
            color: #515151;
        }

        .content button {
            display: inline-block;
            margin-top: 2rem;
            padding: 0.8rem 1rem;
            border: 3px solid #595959;
            background: transparent;
            font-size: 1.11rem;
            color: #595959;
            text-decoration: none;
            cursor: pointer;
            font-weight: bolder;
        }

        .content #time {
            font-size: 1rem;
            font-weight: bolder;
            position: absolute;
            top: 1rem;
            left: 1rem;
        }

        .content #battery {
            position: absolute;
            top: .6rem;
            right: 1rem;
        }

        .content #battery img {
            width: 22px;
        }

        #button {
            position: absolute;
            text-decoration: none;
            left: 50%;
            transform: translateX(-50%);
            bottom: 4rem;
            font-size: 1rem;
            padding: .5rem 2.5rem;
            border-radius: .33rem;
            color: #fff;
            background: #4ECCA3;
        }
        #button:hover {

        }

        .particle {
            position: absolute;
            display: block;
            pointer-events: none;
        }

        @keyframes apparition {
            from {
                opacity: 0;
                transform: translateY(-100px);
            }
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        @keyframes float {
            0%, 100% {
                transform: translateY(0);
            }
            50% {
                transform: translateY(200px);
            }
        }
    </style>
</head>
<body>
<main class="container">
    <article class="content">
        <span id="time"></span>
        <span id="battery"><img
                src=""></span>
        <h1 style="margin: 4rem 0 0; font-size: 4rem">404</h1>
        <h1 style="margin: 1rem 0 0; font-size: 2rem">Not Found</h1>
        <p>页面不存在或已被删除</p>
        <a id="button" href="https://zzzmh.cn">返回</a>
    </article>
</main>
<script>
    // 给背景加点好玩的
    const element = document.querySelector('.container');
    for (let i = 0; i < 256; i++) {
        const span = document.createElement('span');
        span.className = 'particle';
        span.style.top = random(0, 100) + '%';
        span.style.left = random(0, 100) + '%';
        span.style.fontSize = random(24, 48, true) + 'px';
        span.style.fontWeight = random(500, 700);
        span.style.filter = 'blur(' + random(0, 1) + 'px)';
        span.style.animation = random(5, 15) + 's float infinite';
        span.innerHTML = String.fromCharCode(random(0, 6000, true));
        // 改为 模拟黑客帝国
        span.style.color = 'rgb(' + random(0, 50, true) + ',' + random(50, 255, true) + ',' + random(0, 50, true) + ')';
        element.appendChild(span);
    }

    function random(min, max, isInteger) {
        const number = Math.random() * (max - min) + min;
        return isInteger ? Math.floor(number) : number;
    }

    Date.prototype.Format = function (fmt) { //author: meizz
        const o = {
            "M+": this.getMonth() + 1, //月份
            "d+": this.getDate(), //日
            "h+": this.getHours(), //小时
            "m+": this.getMinutes(), //分
            "s+": this.getSeconds(), //秒
            "q+": Math.floor((this.getMonth() + 3) / 3), //季度
            "S": this.getMilliseconds() //毫秒
        };
        if (/(y+)/.test(fmt)) {
            fmt = fmt.replace(RegExp.$1, (this.getFullYear() + "").substr(4 - RegExp.$1.length));
        }
        for (let k in o) {
            if (new RegExp("(" + k + ")").test(fmt)) {
                fmt = fmt.replace(RegExp.$1, (RegExp.$1.length == 1) ? (o[k]) : (("00" + o[k]).substr(("" + o[k]).length)));
            }
        }
        return fmt;
    }

    const time = document.querySelector('#time');
    time.innerHTML = (new Date()).Format("hh:mm");

    setInterval(function () {
        time.innerHTML = (new Date()).Format("hh:mm");
    }, 1000)
</script>
</body>
</html>
